package com.hyt.it.ogt.ykcj.domain.system;

import java.util.Date;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.hyt.it.ogt.ykcj.common.annotation.Excel;
import com.hyt.it.ogt.ykcj.common.core.domain.BaseEntity;

/**
 * 定时任务对象 sys_scheduled_cron
 * 
 * @author admin
 * @date 2021-06-24
 */
public class SysScheduledCron extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键id */
    private Long cronId;

    /** 定时任务完整类名 */
    @Excel(name = "定时任务完整类名")
    private String cronKey;

    /** cron表达式 */
    @Excel(name = "cron表达式")
    private String cronExpression;

    /** 任务描述 */
    @Excel(name = "任务描述")
    private String taskExplain;

    /** 状态,0:处理中;1:处理成功;2:处理失败 */
    @Excel(name = "状态,0:处理中;1:处理成功;2:处理失败")
    private Integer status;

    /** 执行开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "执行开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date startTime;

    /** 执行结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "执行结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endTime;

    public void setCronId(Long cronId)
    {
        this.cronId = cronId;
    }

    public Long getCronId()
    {
        return cronId;
    }
    public void setCronKey(String cronKey)
    {
        this.cronKey = cronKey;
    }

    public String getCronKey()
    {
        return cronKey;
    }
    public void setCronExpression(String cronExpression)
    {
        this.cronExpression = cronExpression;
    }

    public String getCronExpression()
    {
        return cronExpression;
    }
    public void setTaskExplain(String taskExplain)
    {
        this.taskExplain = taskExplain;
    }

    public String getTaskExplain()
    {
        return taskExplain;
    }
    public void setStatus(Integer status)
    {
        this.status = status;
    }

    public Integer getStatus()
    {
        return status;
    }
    public void setStartTime(Date startTime)
    {
        this.startTime = startTime;
    }

    public Date getStartTime()
    {
        return startTime;
    }
    public void setEndTime(Date endTime)
    {
        this.endTime = endTime;
    }

    public Date getEndTime()
    {
        return endTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("cronId", getCronId())
                .append("cronKey", getCronKey())
                .append("cronExpression", getCronExpression())
                .append("taskExplain", getTaskExplain())
                .append("status", getStatus())
                .append("startTime", getStartTime())
                .append("endTime", getEndTime())
                .toString();
    }
}
